# Maintainer: Justin Davis (juster) <jrcd83@gmail.com>
# $Id: PKGBUILD 71635 2012-05-31 15:12:33Z juster $

pkgname=perl-test-fatal
pkgver=0.010
pkgrel=1
pkgdesc='incredibly simple helpers for testing code with exceptions'
arch=(any)
license=(PerlArtistic GPL)
options=(!emptydirs)
depends=('perl-try-tiny>=0.07')
url=https://metacpan.org/release/Test-Fatal
source=("http://search.cpan.org/CPAN/authors/id/R/RJ/RJBS/Test-Fatal-$pkgver.tar.gz")
md5sums=(d8052d4160e8d999cbeb574592f26541)
sha512sums=(24ed85a957e316f49673613295978ff4f2485f762427a8e51594221fe7601d6df3ab1d92dd5a9a8943cce42a04a3a712b781a7ae31403995a03bbf177006edf6)
_dir="$srcdir/Test-Fatal-$pkgver"

build()
(
  cd "$_dir"
  export PERL_MM_USE_DEFAULT=1 PERL_AUTOINSTALL=--skipdeps
  unset PERL5LIB PERL_MM_OPT
  /usr/bin/perl Makefile.PL
  make
)

check()
(
  cd "$_dir"
  export PERL_MM_USE_DEFAULT=1
  unset PERL5LIB
  make test
)

package()
(
  cd "$_dir"
  make install INSTALLDIRS=vendor DESTDIR="$pkgdir"
  find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
)

# Local Variables:
# mode: shell-script
# sh-basic-offset: 2
# End:
# vim:set ts=2 sw=2 et:
